<template>
    <div v-for="(value,name) in user" :key="name">
        属性名是: {{ name }} --- 属性值是: {{ value }}
    </div>
</template>

<script setup>
import { reactive } from 'vue';
const user = reactive({id:11, name:'墨默', gender:'女'})
</script>